package org.dizem.groupon.dao;

import org.dizem.groupon.model.domain.OrderFormEntity;
import org.dizem.groupon.model.domain.UserEntity;

import java.util.List;

/**
 * User: dizem
 * Time: 11-7-21 下午2:36
 */
public interface OrderFormDAO extends DAOSupport<OrderFormEntity> {
	List<OrderFormEntity> getByUser(UserEntity user);

	List<OrderFormEntity> getByItemId(int itemId);

	int getWaitingCount();

	int getSuccessCount();

	int getTodayCount();

	List<OrderFormEntity> getWaitingList(int firstResult, int maxResult);

	List<OrderFormEntity> getSuccessList(int firstResult, int maxResult);

	List<OrderFormEntity> getOrderFormsToday(int firstResult, int maxResult);

	void acceptOrder(int id);

}
